package com.ruoyi.ade.llm.model;

import com.alibaba.fastjson.JSONObject;
import org.jetbrains.annotations.NotNull;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;

public class AdeMilvusResponse implements  Comparable{

    private  String id;
    private String text;
    private String ade;

    private String explain;
    private float score;

    public AdeMilvusResponse(String id, String text, String ade,String explain, float score) {
        this.id = id;
        this.text = text;
        this.ade = ade;
        this.score = score;
        this.explain = explain;
    }

    @Override
    public int compareTo(@NotNull Object o) {
        AdeMilvusResponse r = (AdeMilvusResponse)o;
        return r.getScore()-this.getScore()>0?1:-1;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getText() {
        return text;
    }

    public void setText(String text) {
        this.text = text;
    }

    public String getAde() {
        return ade;
    }

    public void setAde(String ade) {
        this.ade = ade;
    }

    public String getExplain() {
        return explain;
    }

    public void setExplain(String explain) {
        this.explain = explain;
    }

    public float getScore() {
        return score;
    }

    public void setScore(float score) {
        this.score = score;
    }

}
